{literal}
<script type="text/javascript">

	$(document).ready(function(){ 	    
		$("#formularz_zamowienia_email").submit(function() {
			return__ = true;
				
			if ($("#kwota").val() == "" || $("#kwota").val() == 0) {
				$("#kwota__").text("Brak kwoty. Tranzakcja nie może być kontynuowała").show().fadeOut(2000);
				return false;
			}else{
				return__ = (return__) ? true : false ;
			}
			
			if ($("#waluta").val() == "") {
				$("#kwota__").text("Brak waluty. Tranzakcja nie może być kontynuowała").show().fadeOut(2000);
				return false;
			}else{
				return__ = (return__) ? true : false ;
			}

			if ($("#forename").val() == "") {
				$("#forename__").text("Proszę podać imię").show().fadeOut(2000);
				return false;
			}else{
				return__ = (return__) ? true : false ;
			}

			if ($("#surname").val() == "") {
				$("#surname__").text("Proszę podać nazwisko").show().fadeOut(2000);
				return false;
			}else{
				return__ = (return__) ? true : false ;
			}

			if ($("#street").val() == "") {
				$("#street__").text("Proszę podać nazwę i numer ulicy").show().fadeOut(2000);
				return false;
			}else{
				return__ = (return__) ? true : false ;
			}

			if ($("#city").val() == "") {
				$("#city__").text("Proszę podać nazwę miasta").show().fadeOut(2000);
				return false;
			}else{
				return__ = (return__) ? true : false ;
			}
			
			if ($("#postcode").val() == "") {
				$("#postcode__").text("Proszę podać kod pocztowy").show().fadeOut(2000);
				return false;
			}else{
				return__ = (return__) ? true : false ;
			}	

			if ($("#email").val() == "") {
				$("#email__").text("Proszę podać adres e-mail").show().fadeOut(2000);
				return false;
			}else{
				return__ = (return__) ? true : false ;
			}

			if ($("#phone").val() == "") {
				$("#phone__").text("Proszę podać numer telefonu").show().fadeOut(2000);
				return false;
			}else{
				return__ = (return__) ? true : false ;
			}

			if ($("#nip").val() == "") {
				$("#nip__").text("Proszę podać numer NIP").show().fadeOut(2000);
				return false;
			}else{
				return__ = (return__) ? true : false ;
			}
					
			return return__;
	    });
	    
	 
	});

</script>
{/literal}
<form id="formularz_zamowienia_email" action="{$smarty.const.HTTP_URL}{$smarty.request.page},Koszyk,wyslijZamowienieSklepu.html" method="post">

	<table border="0" cellpadding="0" cellspacing="0" id="glowna">
		<tr>
			<th>
				Tytułem:
			</th>
			<td colspan="2">
				<textarea cols="30" rows="5" name="opis" id="opis" readonly>{section name=id loop=$koszyk}{$koszyk[id].ProdukIlosc|default:1} # {$koszyk[id].ProdukNazwa|wordwrap:17:" ":true} # {if not empty($koszyk[id].ProdukSymbol)}{$koszyk[id].ProdukSymbol}{else}PROD{$koszyk[id].ProdukID}-{$koszyk[id].KategoID}{/if};
{/section}</textarea>
				<span style="color: red;" id="opis__"></span>
			</td>
			
        </tr>
		<tr>
			<th>
				Kwota:
			</th>
			<td>
				<input type="text" name="kwota" id="kwota" size="15" value="{$razemkoszyk.RazemBrutto|default:'0.00'}" readonly />
				<select name="waluta" id="waluta" onchange="document.location='{$smarty.const.HTTP_URL}{$smarty.request.page},,okresl_sposob_zaplaty.html?waluta='+this.value;">
					<option value="PLN" {if $waluta eq 'PLN'}selected="selected"{/if}>PLN</option>
					<option value="EUR" {if $waluta eq 'EUR'}selected="selected"{/if}>EUR</option>
					<option value="USD" {if $waluta eq 'USD'}selected="selected"{/if}>USD</option>
				</select>
				<span style="color: red;" id="kwota__"></span>
			</td>
			
			<td rowspan="10" style="padding: 10px; border-left: solid 1px #666666;" valign="middle">
				{if $kupujacy.zalogowany eq 'nie'}
				Jeśli jesteś już użytkownikiem {$smarty.const.HTTP_URL}<br/>
				<a href="zaloguj_sie.html?url={$smarty.request.page},,okresl_sposob_zaplaty.html">zaloguj się</a>
				{else}
				zalogowany jako: {$kupujacy.imie}
				{/if}
			</td>
		</tr>	    
		<tr>
			<th>
				imię:
			</th>
			<td>
				<input class="in" type="text" name="forename" id="forename" value="{$kupujacy.imie}"><br/>
				<span style="color: red;" id="forename__"></span>
			</td>
		</tr>
		<tr>
			<th>
				nazwisko:
			</th>
			<td>
				<input class="in" type="text" name="surname" id="surname" value="{$kupujacy.nazwisko}">
				<span style="color: red;" id="surname__"></span>
			</td>
		</tr>
		<tr>
			<th>
				ulica:
			</th>
			<td>
				<input class="in" type="text" name="street" id="street" value="{$kupujacy.adres}">
				<span style="color: red;" id="street__"></span>
			</td>
		</tr>
		<tr>
			<th>
				numer domu:
			</th>
			<td>
				<input class="in" type="text" name="street_n1" id="street_n1" value="">
			</td>
		</tr>
		<tr>
			<th>
				numer mieszkania:
			</th>
			<td>
				<input class="in" type="text" name="street_n2" value="">
			</td>
		</tr>
		<tr>
			<th>
				miejscowość:
			</th>
			<td>
				<input class="in" type="text" name="city" id="city" value="{$kupujacy.miasto}">
				<span style="color: red;" id="city__"></span>
			</td>
		</tr>
		<tr>
			<th>
				kod pocztowy:
			</th>
			<td>
				<input class="in" type="text" name="postcode" id="postcode" value="{$kupujacy.kodpocztowy}">
				<span style="color: red;" id="postcode__"></span>
			</td>
		</tr>
		<tr>
			<th>
				kraj:
			</th>
			<td>
				<select name="country" id="country">
					<option VALUE="DZA" >Algeria</option>
					<option VALUE="AND" >Andorra</option>
					<option VALUE="AIA" >Anguilla</option>
					<option VALUE="ATG" >Antigua</option>
					<option VALUE="ARG" >Argentina</option>
					<option VALUE="ARM" >Armenia</option>
					<option VALUE="ABW" >Aruba</option>
					<option VALUE="AUS" >Australia</option>
					
					<option VALUE="AUT" >Austria</option>
					<option VALUE="AZE" >Azebaijan</option>
					<option VALUE="BHS" >Bahamas</option>
					<option VALUE="BHR" >Bahrain</option>
					<option VALUE="BGD" >Bangladesh</option>
					<option VALUE="BRB" >Barbados</option>
					<option VALUE="BLR" >Belarus</option>
					<option VALUE="BEL" >Belgium</option>
					<option VALUE="BLZ" >Belize</option>
					
					<option VALUE="BMU" >Bermuda</option>
					<option VALUE="BOL" >Bolivia</option>
					<option VALUE="BWA" >Botswana</option>
					<option VALUE="BRA" >Brazil</option>
					<option VALUE="SLB" >British Solomon Islands</option>
					<option VALUE="BRN" >Brunei</option>
					<option VALUE="BGR" >Bulgaria</option>
					<option VALUE="CAN" >Canada</option>
					<option VALUE="CYM" >Cayman Islands</option>
					
					<option VALUE="CHL" >Chile</option>
					<option VALUE="CHN" >China</option>
					<option VALUE="COL" >Colombia</option>
					<option VALUE="CRI" >Costa Rica</option>
					<option VALUE="HRV" >Croatia</option>
					<option VALUE="CYP" >Cyrus</option>
					<option VALUE="CZE" >Czech Republic</option>
					<option VALUE="DNK" >Denmark</option>
					<option VALUE="DMA" >Dominica</option>
					
					<option VALUE="DOM" >Dominican Republic</option>
					<option VALUE="ECU" >Ecuador</option>
					<option VALUE="EGY" >Egypt</option>
					<option VALUE="SLV" >El Salvador</option>
					<option VALUE="EST" >Estonia</option>
					<option VALUE="FJI" >Fiji</option>
					<option VALUE="FIN" >Finland</option>
					<option VALUE="FRA" >France</option>
					<option VALUE="PYF" >French Polynesia</option>
					
					<option VALUE="DEU" >Germany</option>
					<option VALUE="GHA" >Ghana</option>
					<option VALUE="GRC" >Greece</option>
					<option VALUE="GUM" >Guam</option>
					<option VALUE="GTM" >Guatemal</option>
					<option VALUE="GUY" >Guyana</option>
					<option VALUE="HTI" >Haiti</option>
					<option VALUE="HND" >Honduras</option>
					<option VALUE="HKG" >Hong-Kong</option>
					
					<option VALUE="HUN" >Hungary</option>
					<option VALUE="ISL" >Iceland</option>
					<option VALUE="IND" >India</option>
					<option VALUE="IDN" >Indonesia</option>
					<option VALUE="IRN" >Iran</option>
					<option VALUE="IRL" >Ireland</option>
					<option VALUE="ISR" >Israel</option>
					<option VALUE="ITA" >Italy</option>
					<option VALUE="JAM" >Jamaica</option>
					
					<option VALUE="JPN" >Japan</option>
					<option VALUE="JOR" >Jordan</option>
					<option VALUE="KAZ" >Kazakhstan</option>
					<option VALUE="KEN" >Kenya</option>
					<option VALUE="KOR" >Korea</option>
					<option VALUE="KWT" >Kuwait</option>
					<option VALUE="LVA" >Latvia</option>
					<option VALUE="LBN" >Lebanon</option>
					<option VALUE="LTU" >Lithuania</option>
					
					<option VALUE="LUX" >Luxembourg</option>
					<option VALUE="MAC" >Macao</option>
					<option VALUE="MKD" >Macedonia</option>
					<option VALUE="MDG" >Madagascar</option>
					<option VALUE="MYS" >Malaysia</option>
					<option VALUE="MLT" >Malta</option>
					<option VALUE="MUS" >Mauritius</option>
					<option VALUE="MEX" >Mexico</option>
					<option VALUE="MAR" >Morocco</option>
					
					<option VALUE="MOZ" >Mozambique</option>
					<option VALUE="NAM" >Namibia</option>
					<option VALUE="NPL" >Nepal</option>
					<option VALUE="NDL" >Netherlands</option>
					<option VALUE="ANT" >Netherlands Antiles</option>
					<option VALUE="NZL" >NewZeland</option>
					<option VALUE="NIC" >Nicaragua</option>
					<option VALUE="NGA" >Nigeria</option>
					<option VALUE="NOR" >Norway</option>
					
					<option VALUE="OMN" >Oman</option>
					<option VALUE="PAK" >Pakistan</option>
					<option VALUE="PAN" >Panama</option>
					<option VALUE="PNG" >Papua New Guinea</option>
					<option VALUE="PRY" >Paraguay</option>
					<option VALUE="PER" >Peru</option>
					<option VALUE="PHL" >Philippines</option>
					<option VALUE="POL" selected>Polska</option>
					<option VALUE="PRT" >Portugal</option>
					
					<option VALUE="QAT" >Qatar</option>
					<option VALUE="ROM" >Romania</option>
					<option VALUE="RUS" >Russia</option>
					<option VALUE="WSM" >Samoa</option>
					<option VALUE="SAU" >SaudiArabia</option>
					<option VALUE="SEN" >Senegal</option>
					<option VALUE="SYC" >Seychelles</option>
					<option VALUE="SLE" >Sierra Leone</option>
					<option VALUE="SGP" >Singapore</option>
					
					<option VALUE="SVK" >Slovakia</option>
					<option VALUE="SVN" >Slovenia</option>
					<option VALUE="ZAF" >South Africa</option>
					<option VALUE="ESP" >Spain</option>
					<option VALUE="LKA" >Sri Lanka</option>
					<option VALUE="KNA" >St.Kitts-Nevis-Anguilla</option>
					<option VALUE="LCA" >St.Lucia</option>
					<option VALUE="SAN" >St.Martin</option>
					<option VALUE="VCT" >St.Vincent</option>
					
					<option VALUE="SUR" >Suriname</option>
					<option VALUE="SWE" >Sweden</option>
					<option VALUE="CHE" >Switzerland</option>
					<option VALUE="TWN" >Taiwan</option>
					<option VALUE="THA" >Thailand</option>
					<option VALUE="TON" >Tonga</option>
					<option VALUE="TTO" >Trinidad And Tobago</option>
					<option VALUE="TUN" >Tunisia</option>
					<option VALUE="TUR" >Turkey</option>
					
					<option VALUE="TCA" >Turks And Caicos Island</option>
					<option VALUE="UKR" >Ukrainian</option>
					<option VALUE="ARE" >United Arab Emirates</option>
					<option VALUE="GBR" >United Kingdom</option>
					<option VALUE="USA" >United States Of America</option>
					<option VALUE="URY" >Uruguay</option>
					<option VALUE="UZB" >Uzbekistan</option>
					<option VALUE="VEN" >Venezuela</option>
					<option VALUE="VNM" >Vietnam</option>
					
					<option VALUE="ZWE" >Zimbabwe</option>
				</select>
				<br/><span style="color: red;" id="country__"></span>
			</td>
		</tr>
		<tr>
			<th>
				adres email:
			</th>
			<td>
				<input class="in" type="text" name="email" id="email" value="{$kupujacy.email}">
				<br/><span style="color: red;" id="email__"></span>
			</td>
		</tr>
		<tr>
			<th>
				numer telefonu:
			</th>
			<td>
				<input class="in" type="text" name="phone" id="phone"  value="{$kupujacy.telefon}">
				<br/><span style="color: red;" id="phone__"></span>
			</td>
		</tr>
				<tr>
			<th>
				NIP:
			</th>
			<td>
				<input class="in" type="text" name="nip" id="nip" value="{$kupujacy.nip}">
				<br/><span style="color: red;" id="nip__"></span>
			</td>
		</tr>
		<tr>
			<th>
				Uwagi:
			</th>
			<td colspan="2">
				<textarea cols="30" rows="5" name="uwagi" id="uwagi"></textarea>
				<span style="color: red;" id="uwagi__"></span>
			</td>
			
        </tr>		
		<tr>
			<th colspan="3">
				<input type="submit" value="Wyślij zamówienie">
			</th>
		</tr>
 </table>
</form>
